using System;
using System.Collections.Generic;
using System.Text;

namespace Yorrick.FlickrMetadataSynchr.Events
{
   /// <summary>
   /// Event arguments class for an event that communicates the progress when processing pictures.
   /// </summary>
   public class PictureProgressEventArgs: EventArgs
   {
      /// <summary>
      /// The number of the current picture being processed.
      /// </summary>
      private int _currentPictureNumber;

      /// <summary>
      /// The total number of pictures to process.
      /// </summary>
      private int _totalNumberOfPictures;

      /// <summary>
      /// Whether or not to cancel the process.
      /// </summary>
      private bool _cancelProcess;

      /// <summary>
      /// Gets the number of the current picture being processed.
      /// </summary>
      public int CurrentPictureNumber
      {
         get
         {
            return _currentPictureNumber;
         }
      }

      /// <summary>
      /// Gets the total number of pictures to process.
      /// </summary>
      public int TotalNumberOfPictures
      {
         get
         {
            return _totalNumberOfPictures;
         }
      }

      /// <summary>
      /// Gets or sets whether or not to cancel the process.
      /// </summary>
      public bool CancelProcess
      {
         get
         {
            return _cancelProcess;
         }
         set
         {
            _cancelProcess = value;
         }
      }

      /// <summary>
      /// Constructs an instance.
      /// </summary>
      /// <param name="currentPhotoNumber">The number of the current photo being processed.</param>
      /// <param name="totalNumberOfPhotos">The total number of pictures to process.</param>
      public PictureProgressEventArgs(int currentPhotoNumber, int totalNumberOfPhotos)
      {
         _currentPictureNumber = currentPhotoNumber;
         _totalNumberOfPictures = totalNumberOfPhotos;
      }
   }
}
